fix windows issues with kml.h including windows.h (#551)
authortsteven4 <13596209+tsteven4@users.noreply.github.com>
Fri, 1 May 2020 22:12:29 +0000 (16:12 -0600)
committerGitHub <noreply@github.com>
Fri, 1 May 2020 22:12:29 +0000 (16:12 -0600)
windows.h defines macros for max and min, which lead to compiler
warnings:
random.h(125): warning C4003: not enough arguments for function-like macro invocation 'max' (compiling source file

kml hasn't needed windows.h since ea82fa6d6

kml.cc
kml.h

diff --git a/kml.cc b/kml.cc
index 83c0d18e9c94a3a51673d99915370a95aa8f86f1..10286989350693ed8ec7799bed032d6484568c71 100644 (file)
--- a/kml.cc
+++ b/kml.cc
 
  */
 
-#ifdef __WIN32__
-# include <windows.h>
-#endif
-
 #include <cctype>                       // for tolower, toupper
 #include <cmath>                        // for fabs
 #include <cstdio>                       // for sscanf, printf
diff --git a/kml.h b/kml.h
index edf2a4e6ba0dc7802be973dfcfe99ddad67d58d3..375d50d08a503ff9c53e25eb2873f36d4932191b 100644 (file)
--- a/kml.h
+++ b/kml.h
 #ifndef KML_H_INCLUDED_
 #define KML_H_INCLUDED_
 
-#ifdef __WIN32__
-# include <windows.h>
-#endif
-
 #include <tuple>                        // for tuple, make_tuple, tie
 
 #include <QtCore/QList>                 // for QList